<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=7" />
<title>订单预定登录</title>
<link href="<c:url value="/resource/dwz/themes/default/style.css"/>" rel="stylesheet" type="text/css" media="screen"/>
<link href="<c:url value="/resource/dwz/themes/css/core.css"/>" rel="stylesheet" type="text/css" media="screen"/>
<link href="<c:url value="/resource/dwz/themes/css/print.css"/>" rel="stylesheet" type="text/css" media="print"/>
<script src="<c:url value="/resource/dwz/js/jquery-1.7.2.min.js"/>" type="text/javascript"></script>
<script src="<c:url value="/resource/dwz/js/jquery.validate.js"/>" type="text/javascript"></script>
<script src="<c:url value="/resource/dwz/bin/dwz.min.js"/>" type="text/javascript"></script>
<script src="<c:url value="/resource/dwz/js/jquery.cookie.js"/>" type="text/javascript"></script>


<script type="text/javascript">
$(function(){
	DWZ.init("dwz.frag.xml", {
		callback:function(){
			initUI();
			var themeName = $.cookie("dwz_theme")||'default';
			var _themeHref = '<c:url value="/resource/dwz/themes/#theme#/style.css"/>';
			$("head").find("link[href$='style.css']").attr("href", _themeHref.replace("#theme#", themeName));
			window.setTimeout(function(){
				$('#account').focus();
			},50);
		}
	});
});
function forwardMain(json){

	if(json.statusCode==DWZ.statusCode.error){
		if(json.message&&alertMsg)alertMsg.error(json.message);
	}else if(json.statusCode==DWZ.statusCode.timeout){
		if(alertMsg)
			alertMsg.error(json.message||DWZ.msg("sessionTimout"),{okCall:DWZ.loadLogin});
		else 
			DWZ.loadLogin();
	}else{
		window.location.href = '<c:url value="/forward.do?jspName=client_main"/>';
	};
}
</script>
<style type="text/css">
	.panel{
		width: 300px;
	}
	.panel h1{
		text-align: left;
	}
	.unit{
		overflow: hidden;
	}
	.center {
		position: absolute;
		top: 50%;
		margin-top: -88px;
		left: 50%;
		margin-left: -150px;
	}
</style>
</head>
<body scroll="no">
<form class="pageForm required-validate" action="<c:url value="/clientLogin.do"/>" method="post" onsubmit="return validateCallback(this,forwardMain)">
	<div class="panel center">
		<h1>系统登录</h1>
     		<div class="pageFormContent" style="height: 100px; overflow: hidden;width:288px;">
				<dl>
					<dt>用户名：</dt>
					<dd>
						<input type="text" name="phone" maxlength="20" class="required textInput" id="account"/>
					</dd>
				</dl>
				<dl>
					<dt>密码：</dt>
					<dd>
						<input type="password" name="password" maxlength="20" class="required textInput" id = "password"/>

					</dd>
				</dl>
				<c:if test="${msg!=null}">
				<dl style="color:red;font-weight: bold;">
					<dt>提示信息：</dt>
					<dd style="text-align: left">
						<c:out value="${msg}"/>
					</dd>
				</dl>
				</c:if>
			</div>
     		 <div class="formBar">
				<ul>
					<li><div class="buttonActive"><div class="buttonContent"><button type="submit">登录</button></div></div></li>
					<li><div class="button"><div class="buttonContent"><button class="close" type="reset">重置</button></div></div></li>
				</ul>
			</div>
	</div>
</form>
</body>
</html>